
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
    <meta content="360doc" name="classification" />
    
    <link rel="alternate" media="only screen and (max-width: 640px)" href="http://www.360doc.cn/article/7044580_275633208.html"/>
    <meta content="nand,mini,mach" name=keywords>
    <meta content="Linux-2.6.32.2内核在mini2440上的移植" name=description>
    <meta name="mobile-agent" content="format=html5;url=http://www.360doc.cn/article/7044580_275633208.html"/>

    <meta content="www.360doc.com" name="author" />

    <title>
        Linux-2.6.32.2内核在mini2440上的移植
    </title>
    <link href="http://bdimg.share.baidu.com/static/css/bdsstyle.css?cdnversion=20130704" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="http://libs.baidu.com/jquery/1.4.4/jquery.min.js"></script>
    <script type="text/javascript" src="http://www.360doc.com/js/jQuery.md5.js?t=2013121101"></script>
    
    <script type="text/javascript" language="javascript">
        window.onerror = ignoreError;
        function ignoreError() {
            return true;
        }
    </script>

    <link href="http://css.360doc.com/wzhead-cleaned.css?t=2014060601" rel="stylesheet" type="text/css" />
    <link href="http://css.360doc.com/wz20130912-cleaned.css?t=2014070103" rel="stylesheet" type="text/css" />


    

    <script type="text/javascript" src="/js/indexhead.js?t=2014061905"></script>
    <script type="text/javascript" src="/js/showarticlefollow20130912.js?t=2014072302"></script>
</head>
<body style="font-family: Arial, Helvetica, sans-serif;" onmouseup="setDragEnd()"
    onmousemove="DragDiv();" onclick="delAllDiv(event)">

    <span id="LayerLogin"></span>
    <div class="mainnav">
        <div class="mainnav1">
            <div class="lf360" style="padding-top: 5px; padding-left: 10px; position: relative;">
                <a href="/index.html">
                    <img src="http://pubimage.360doc.com/index/sy-8.gif" /></a>
            </div>
            <div style="position: absolute; padding-top: 12px; padding-left: 4px; width: 525px;">
                <table border="0" cellpadding="0" cellspacing="0" height="34">
                    <tbody>
                        <tr>
                            <td style="width: 110px; *width: 0px; _width: 0px;"></td>
                            <td width="100px" class="  navwz1">
                                <a href="/index.html">首&nbsp;页</a>
                            </td>
                            <td width="100px" class="  navwz1">
                                <a href="/readroom.html">阅览室</a>
                            </td>
                            <td width="88px" class="  navwz1">
                                <a href="/weekstar.html">馆友</a>
                            </td>
                            <td width="132px" class="  navwz1">
                                <a href="http://www.360doc.com/my360doc.aspx">我的图书馆</a>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            <div class="rt360" style="padding-top: 18px; width: 200px;" id="outerdiv">
            </div>
            <div class=" rt360" style="padding-top: 17px; padding-right: 0px;">
                <div class="lf360 serch">
                    <input id="txtSearchword" onkeyup="showIntelliSense()" name="input2" type="text"
                        class="serchpt" value="搜文章 找馆友" onblur="if(!this.value) {this.value='搜文章 找馆友';this.style.color='#b2b2b2';}"
                        onfocus="if(this.value=='搜文章 找馆友') this.value='';this.style.color='#272727'"
                        onkeydown="ongosearch()" onpaste="showIntelliSense1();" />
                </div>
                <div class="lf360 ssuo" style="position: relative;">
                    <a href="javascript:gosearch();" id="searchlinkid"></a>
                </div>
                <div id="divsearch" style="position: absolute; margin-top: 25px; margin-left: 1px; *margin-left: -223px; z-index: 100; display: block;">
                </div>
            </div>
        </div>
    </div>
    <div class="navxt">
    </div>
    <div class="both">
    </div>
    <div class="mainzt">
        <table class="index_main" border="0" cellpadding="0" cellspacing="0">
            <tbody>
                <tr>
                    <td align="left" valign="top" width="727px">
                        <div id='ADAboveArtContent'>
                        </div>
                        <div style="height: 7px;">
                        </div>
                        <table border="0" cellpadding="0" cellspacing="0" class="mainbj" id="docArtClass">
                            <tbody>
                                <tr>
                                    <td>
                                        <table border="0" cellpadding="0" cellspacing="0" style="width: 100%; text-align: center;">
                                            <tbody>
                                                <tr>
                                                    <td>
                                                        <table style="width: 100%; text-align: left;" border="0" cellpadding="0" cellspacing="0">
                                                            <tbody>
                                                                <tr>
                                                                    <td class="biaoti">
                                                                        <div class="biaoti2 lf360">
                                                                            Linux-2.6.32.2内核在mini2440上的移植
                                                                        </div>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td style="height: 32px;">


                                                                        <div style="width: 670px; height: 28px; padding-left: 26px; color: #777b7a;">
                                                                            <table>
                                                                                <tr>
                                                                                    <td>收藏人：<span class="name" onclick="wzhitnew(1);"><A href="http://www.360doc.com/userhome/7044580" target="_blank">joy_chen</A></span>
                                                                                    </td>
                                                                                    <td>
                                                                                        <div class="btzctsg" id="spanfollowstatus">
                                                                                        </div>
                                                                                        <script>isfollow(7044580);</script>
                                                                                    </td>

                                                                                </tr>
                                                                            </table>
                                                                        </div>




                                                                        <div class="wztopxx">
                                                                            <div style="float: left; height: 28px; padding-top: 7px;">
                                                                                <table cellpadding="0" cellspacing="0" style="position: relative; z-index: 4">
                                                                                    <tbody>
                                                                                        <tr>

                                                                                            <td>
                                                                                                2013-04-03&nbsp;|&nbsp;阅：<span id="360doc_Readnum"></span>&nbsp;&nbsp;<span
                                                                                                    style="position: relative;">转：<span onclick="wzhitnew(3)" id="360doc_saverNum"></span><span
                                                                                                        id="360doc_saverUser"></span></span>&nbsp;&nbsp;



                                                                                            </td>

                                                                                            <td>
                                                                                                <div style="position: relative;">
                                                                                                    &nbsp;|&nbsp;<span id="docsource"></span>
                                                                                                </div>
                                                                                                <div class="sekuaibox" style="display: none; margin-left: 48px;" id="zihaoboxID">
                                                                                                    <div style="padding-top: 10px; padding-left: 5px;">
                                                                                                        <div class="lf360 danxunbt">
                                                                                                            <input id="artdocfont3" onclick="ChangeArtSize(3, this); wzhitnew(15); " name="radio"
                                                                                                                type="radio" value="1" />
                                                                                                        </div>
                                                                                                        <div class="lf360 danxunwz" onclick="ChangeArtSize(3,this);wzhitnew(15); " style="cursor: pointer;">
                                                                                                            大
                                                                                                        </div>
                                                                                                        <div class="lf360 danxunbt">
                                                                                                            <input id="artdocfont2" onclick="ChangeArtSize(2, this); wzhitnew(16); " name="radio"
                                                                                                                type="radio" value="2" />
                                                                                                        </div>
                                                                                                        <div class="lf360 danxunwz" onclick="ChangeArtSize(2,this);wzhitnew(16); " style="cursor: pointer;">
                                                                                                            中
                                                                                                        </div>
                                                                                                        <div class="lf360 danxunbt">
                                                                                                            <input id="artdocfont1" onclick="ChangeArtSize(1, this); wzhitnew(17); " name="radio"
                                                                                                                type="radio" value="3" />
                                                                                                        </div>
                                                                                                        <div class="lf360 danxunwz" onclick="ChangeArtSize(1,this);wzhitnew(17); " style="cursor: pointer;">
                                                                                                            小
                                                                                                        </div>
                                                                                                    </div>
                                                                                                </div>
                                                                                                <div class="sekuaibox" style="margin-left: 76px; display: none;" id="sekuaiboxID">
                                                                                                    <div style="padding-top: 10px; padding-left: 5px;">
                                                                                                        <img src="http://pubimage.360doc.com/wz/cr1.gif" id="docArtC1" onclick="ChangeArtClass(1,this);wzhitnew(18);"
                                                                                                            style="cursor: pointer;" /><img src="http://pubimage.360doc.com/wz/cr2.gif" id="docArtC2"
                                                                                                                onclick="ChangeArtClass(2,this);wzhitnew(19);" style="cursor: pointer;" /><img src="http://pubimage.360doc.com/wz/cr3.gif"
                                                                                                                    id="docArtC3" onclick="ChangeArtClass(3,this);wzhitnew(20);" style="cursor: pointer;" /><img
                                                                                                                        src="http://pubimage.360doc.com/wz/cr4.gif" id="docArtC4" onclick="ChangeArtClass(4,this);wzhitnew(21);"
                                                                                                                        style="cursor: pointer;" /><img src="http://pubimage.360doc.com/wz/cr5.gif" id="docArtC5"
                                                                                                                            onclick="ChangeArtClass(5,this);wzhitnew(22);" style="cursor: pointer;" /><img src="http://pubimage.360doc.com/wz/cr6.gif"
                                                                                                                                id="docArtC6" onclick="ChangeArtClass(6,this);wzhitnew(23);" style="cursor: pointer;" />
                                                                                                    </div>
                                                                                                </div>
                                                                                            </td>
                                                                                            <td>
                                                                                                <div style="padding-left: 10px;">
                                                                                                    <a href="javascript:void(0)">
                                                                                                        <img onmouseover="changedivdisplay(1);" src="http://pubimage.360doc.com/wz/wz1.gif" /></a>
                                                                                                </div>
                                                                                            </td>
                                                                                            <td>
                                                                                                <div style="padding-left: 10px;" onmouseover="changedivdisplay(2);">
                                                                                                    <a href="javascript:void(0)">
                                                                                                        <img src="http://pubimage.360doc.com/wz/wz2.gif" /></a>
                                                                                                </div>
                                                                                            </td>
                                                                                            <td>&nbsp;&nbsp;|&nbsp;&nbsp;<a href="#" onclick=" setTimeout(showShareLayer, 10);wzhitnew(4);">分享</a>&nbsp;</td>
                                                                                            <td>
                                                                                                <a href="#" onclick="  setTimeout(showShareLayer, 10);wzhitnew(5);">
                                                                                                    <img style="cursor: pointer;" src="http://pubimage.360doc.com/wz/tb10.gif"></a><div
                                                                                                        class="fenxiang" id="fenxiangLayer" style="display: none; border: none; width: 110px; margin-left: -28px; _margin-left: -40px;">
                                                                                                    </div>
                                                                                            </td>
                                                                                        </tr>
                                                                                    </tbody>
                                                                                </table>
                                                                            </div>
                                                                            <div id="resavelayer1" class="rt360">
                                                                            </div>


                                                                            <div id="shareweixinabove" class="rt360">
                                                                            </div>


                                                                            <table cellpadding="0" cellspacing="0" style="text-align: center; margin: 0px auto;">
                                                                                <tbody>
                                                                                    <tr>
                                                                                        <td>
                                                                                            <div id="AlertArt1" style="display: none; position: absolute;">
                                                                                            </div>
                                                                                            <div id="SendToFriends1" style="display: none; position: absolute; z-index: 100;">
                                                                                            </div>
                                                                                            <div class="lf360 zcbutton" style="margin-left: 100px;">
                                                                                            </div>
                                                                                            <div class="lf360">
                                                                                                &nbsp;&nbsp;
                                                                                            </div>
                                                                                        </td>
                                                                                    </tr>
                                                                                </tbody>
                                                                            </table>
                                                                        </div>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td></td>
                                                                </tr>
                                                            </tbody>
                                                        </table>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td>
                                                        
                                                        <table class="wenzhangcss" border="0" cellpadding="0" cellspacing="0" width="100%">
                                                            <tbody>
                                                                <tr>
                                                                    <td>
                                                                        <div class="xiantao">
                                                                        </div>

                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td align="left" valign="top" width="670px" style="height: 200px;">
                                                                        <span id="articlecontent" onmousedown="newhighlight = true;" onmouseup="NewHighlight(event)">
                                                                            <table>
                                                                                <tbody>
                                                                                    <tr>
                                                                                        <td width="670px" style="position: relative;">

                                                                                            <a href="http://singleboy.blog.163.com/blog/static/5490019420114251536390/">http://singleboy.blog.163.com/blog/static/5490019420114251536390/</a><div><br></div><div><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">移植环境(<font color="#ff0000"><strong>红色粗字体字</strong></font><font color="#000000">为</font>修改后内容，<strong><font color="#0000ff">蓝色粗体字</font></strong>为特别注意内容)</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">1，主机环境：VMare下CentOS 5.5 ，1G内存。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">2，集成开发环境：Elipse IDE</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">3，编译编译环境：arm-linux-gcc v4.4.3，arm-none-linux-gnueabi-gcc v4.5.1。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">4，开发板：mini2440，2M nor flash，128M nand flash。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">5，u-boot版本：u-boot-2009.08</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">6，linux 版本：linux-2.6.32.2</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">7，参考文章：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208); text-indent: 2em;">【1】嵌入式linux应用开发完全手册，韦东山，编著。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208); text-indent: 2em;">【2】<a rel="nofollow" href="http://blogold.chinaunix.net/u3/101649/showart_2276906.html" style="color: rgb(76, 76, 76); text-decoration: none;">http://blogold.chinaunix.net/u3/101649/showart_2276906.html</a></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208); text-indent: 2em;">&nbsp;【3】Mini2440 之Linux 移植开发实战指南</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><strong>1.1</strong>，构建自主开发环境</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">我们在进行u-boot移植时，在<a target="_blank" href="http://singleboy.blog.163.com/blog/static/54900194201141282946225/" style="color: rgb(76, 76, 76); text-decoration: none;">u-boot-2009.08在mini2440上的移植（六）---增加引导内核功能</a>提到过机器码(MACH_TYPE)，在引导测试时，为了便于测试，使用的是友善官方移植好的linux内核。现在我们将从这里着手，逐步开始linux内核的移植。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">【1】下载并解压内核源码</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">在命令行终端中可以通过下列方式下载，当然用其它下载工具下载</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[root@localhost ~]# wget&nbsp;<a rel="nofollow" href="http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.32.2.tar.gz" style="color: rgb(76, 76, 76); text-decoration: none;">http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.32.2.tar.gz</a></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">然后解压：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[root@localhost ~]# cd ./linux-test/<br>[root@localhost linux-test]# tar -zxf ../linux-2.6.32.2.tar.gz<br>[root@localhost linux-test]# ls<br><strong><font color="#0000ff">linux-2.6.32.2</font></strong>&nbsp; linux-2.6.39&nbsp; yaffs2&nbsp; yaffs2.tar.gz<br>[root@localhost linux-test]# cd linux-2.6.32.2<br>[root@localhost linux-2.6.32.2]#&nbsp;<br></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">【2】指定交叉编译变量</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">我们移植目的是让 Linux-2.6.32.2 可以在mini2440 上运行。首先，我们要使得Linux-2.6.32.2 的缺省目标平台成为ARM 的平台，修改总目录下的Makefile。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">用gedit打开/Makefile，定位到183行，修改如下：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"># Alternatively CROSS_COMPILE can be set in the environment.<br># Default value for CROSS_COMPILE is not to prefix executables<br># Note: Some architectures assign CROSS_COMPILE in their arch/*/Makefile<br>export KBUILD_BUILDHOST := $(SUBARCH)<br><strong><font color="#ff0000">ARCH&nbsp;&nbsp;?= arm<br>CROSS_COMPILE&nbsp;?= arm-linux-</font></strong></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"># Architecture as present in compile.h</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">其中，ARCH 是指定目标平台为arm，CROSS_COMPILE 是指定交叉编译器，这里指定的是系统默认的交叉编译器，如要使用其它的，则要把编译器的全路径在这里写出。注意，在<strong><font color="#0000ff">arm和arm-linux-后不要留空格</font></strong>，否则在编译时会出现错误。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">接下来，要测试一下linux 的编译是否能正常通过。执行：<br>[root@localhost linux-2.6.32.2]# make s3c2410_defconfig</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">使用缺省内核配置文件,s3c2410_defconfig 是SMDK2440 的缺省配置文件<br>[root@localhost linux-2.6.32.2]# make</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">编译时间较长... ... 。编译通过，在此我们先不必烧写到开发板验证它的正确性。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">【3】建立自己的目标平台</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">(1)关于机器码</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">以上编译是用的 Linux 内核本身支持的目标平台配置，它对应于SMDK2440。现在我们要参考SMDK2440 加入自已的开发板平台，我们使用的是mini2440，因此取名为MINI2440。需要说明的是，Linux-2.6.32.2 本身已经包含了mini2440 的支持，这样就出现了重名。那怎么办呢？在此我们依然使用MINI2440 这个名称，只不过在后面的移植步骤中，把原始内核自带的mini2440 代码部分直接删除就可以了，以免和我们自己移植的混淆。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">首先，很关键的一点，内核在启动时，是通过bootloader 传入的机器码(MACH_TYPE)确定应启动哪种目标平台的，友善之臂已经为mini2440 申请了自己的机器码为1999，它位于linux-2.6.32.2/arch/arm/tools/mach_types 文件中，如下面所示：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">打开/arch/arm/tools/mach-types，定位到1989行，可以看到文件中有相应的机器码的定义定义如下(黑体部分)：<br>exeda&nbsp;&nbsp;&nbsp;MACH_EXEDA&nbsp;&nbsp;EXEDA&nbsp;&nbsp;&nbsp;1994<br>mx31sf005&nbsp;&nbsp;MACH_MX31SF005&nbsp;&nbsp;MX31SF005&nbsp;&nbsp;1995<br>f5d8231_4_v2&nbsp;&nbsp;MACH_F5D8231_4_V2&nbsp;F5D8231_4_V2&nbsp;&nbsp;1996<br>q2440&nbsp;&nbsp;&nbsp;MACH_Q2440&nbsp;&nbsp;Q2440&nbsp;&nbsp;&nbsp;1997<br>qq2440&nbsp;&nbsp;&nbsp;MACH_QQ2440&nbsp;&nbsp;QQ2440&nbsp;&nbsp;&nbsp;1998<br><strong><font color="#0000ff">mini2440&nbsp;&nbsp;MACH_MINI2440&nbsp;&nbsp;MINI2440&nbsp;&nbsp;1999<br></font></strong>colibri300&nbsp;&nbsp;MACH_COLIBRI300&nbsp;&nbsp;COLIBRI300&nbsp;&nbsp;2000<br>jades&nbsp;&nbsp;&nbsp;MACH_JADES&nbsp;&nbsp;JADES&nbsp;&nbsp;&nbsp;2001<br>spark&nbsp;&nbsp;&nbsp;MACH_SPARK&nbsp;&nbsp;SPARK&nbsp;&nbsp;&nbsp;2002<br>benzina&nbsp;&nbsp;&nbsp;MACH_BENZINA&nbsp;&nbsp;BENZINA&nbsp;&nbsp;&nbsp;2003</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">在U-boot/include/asm-arm/mach-types.h 文件的1985行附近(u-boot-2009.08)，可以看到mini2440 的机器码定义如下面所示：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">#define MACH_TYPE_Q2440 1997<br>#define MACH_TYPE_QQ2440 1998<br><strong><font color="#0000ff">#define MACH_TYPE_MINI2440 1999</font>&nbsp; //mini2440的机器码<br></strong>#define MACH_TYPE_COLIBRI300 2000<br>#define MACH_TYPE_JADES 2001</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">这需要两者<font color="#000000">相匹配，</font>如果内核的机器码和bootloader 传入的不匹配，就会经常出现下面的错误：<br>Uncompressing Linux................................................................................................................................. done, booting<br>the kernel.<br>运行到这不就停住了。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">接下来， 我们注意到linux-2.6.32.2/arch/arm/mach-s3c2440 目录下有个mach-mini2440.c 文件，它其实就是国外爱好者为mini2440 移植添加的主要内容了，但我们不用它，把它直接删除。将linux-2.6.32.2/arch/arm/mach-s3c2440/目录下的mach-smdk2440.c 复制一份。命名为mach-mini2440.c ，并打开文件定位到末尾处，找到</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">MACHINE_START(S3C2440, "SMDK2440") ， 将其修改为<br><font color="#ff0000"><strong>MAC</strong></font><strong><font color="#ff0000">HINE</font><font color="#ff0000">_START(MINI2440, "Mini2440 development board")<br></font></strong>提示：开发板运行后，在命令行终端输入：cat /proc/cpuinfo 可以看到我们添加的开发板信息，当然这个信息可以定制成我们需要的信息。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">(2)修改时钟源频率</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">在上面我们刚刚复制并修改过的mach-mini2440.c文件中，定位到163行附近，把其中的16934400(代表原SMDK2440 目标板的晶振是16.9344MHz)改为mini2440 开发板上实际使用的12000000(代表mini2440 开发板上的晶振12MHz，元器件标号为X2)，如下所示：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">static void __init smdk2440_map_io(void)<br>{<br>&nbsp;s3c24xx_init_io(smdk2440_iodesc, ARRAY_SIZE(smdk2440_iodesc));<br>&nbsp;<strong><font color="#ff0000">s3c24xx_init_clocks(12000000);<br></font></strong>&nbsp;s3c24xx_init_uarts(smdk2440_uartcfgs, ARRAY_SIZE(smdk2440_uartcfgs));<br>}</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">(3)从SMDK2440 到MINI2440</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">因为我们要制作自己的mini2440 平台体系，因此把mach-mini2440.c 中所有的smdk2440 字样改为mini2440，可以使用批处理命令修改，在vim 的命令模式下输入：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">%s/smdk2440/mini2440/g<br>上面这句的意思是：把所有和“smdk2440”匹配的字符串全部替换为“mini2440”，前面的“%s“代表字符串匹配，最后的“g”代表global，是全局的意思，不过这里采用另一种办法，在gedit里用查找替换，比较方便，操作如下：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">gedit-&gt;搜索-&gt;替换，在打开的对话框中，在搜索一栏输入“smdk2440”，在替换为一栏输入“mini2440”然后点击全部替换按钮，即可完成。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">除此之外，还有一个地方需要改动，在mini2440_machine_init(void)函数中，把smdk_machine_init()函数调用注释掉，因为我们后面会编写自己的初始化函数，不需要调用smdk2440 原来的，定位到173行，修改如下：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">static void __init mini2440_machine_init(void)<br>{<br>&nbsp;s3c24xx_fb_set_platdata(&amp;mini2440_fb_info);<br>&nbsp;s3c_i2c0_set_platdata(NULL);</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;platform_add_devices(mini2440_devices, ARRAY_SIZE(mini2440_devices));<br>&nbsp;<strong><font color="#ff0000">//smdk_machine_init();<br></font></strong>}</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">(4)编译测试</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">在 Linux 源代码根目录下执行</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[root@localhost linux-2.6.32.2]# make mini2440_defconfig&nbsp;<br>#<br># configuration written to .config<br>#<br>[root@localhost linux-2.6.32.2]# make mini2440_defconfig</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;使用Linux 官方自带的mini2440 配置。<br>[root@localhost linux-2.6.32.2]# make uImage</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;编译内核，时间较长，最后会生成uImage。把生成的内核文件uImage(位于arch/arm/boot 目录)下载到板子的内存中运行，可以看到内核已经可以正常启动了，如下所示，但此时大部分硬件驱动还没加，并且也没有文件系统，因此还无法登陆。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[u-boot@MINI2440]# usbslave&nbsp;<br>USB host is connected. Waiting a download.</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">Now, Downloading [ADDRESS:31000000h,TOTAL:2067310]<br>RECEIVED FILE SIZE: 2067310 (672KB/S, 3S)<br>[u-boot@MINI2440]# go 0x31000000<br>## Starting application at 0x31000000 ...<br>Uncompressing Linux.............................................................<br>................................................................... done, bootin<br>g the kernel.<br>Linux version 2.6.32.2 (<a rel="nofollow" href="mailto:root@localhost.localdomain" style="color: rgb(76, 76, 76); text-decoration: none;">root@localhost.localdomain</a>) (gcc version 4.4.3 (ctng-1.6<br>.1) ) #4 Thu May 26 18:51:55 CST 2011<br>CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=00007177<br>CPU: VIVT data cache, VIVT instruction cache<br>Machine: mini2440 devolopment board<br>Memory policy: ECC disabled, Data cache writeback<br>CPU S3C2440A (id 0x32440001)<br>S3C24XX Clocks, (c) 2004 Simtec Electronics<br>S3C244X: core 405.000 MHz, memory 101.250 MHz, peripheral 50.625 MHz<br>CLOCK: Slow mode (1.500 MHz), fast, MPLL on, UPLL on<br>Built 1 zonelists in Zone order, mobility grouping on.&nbsp; Total pages: 16256<br>Kernel command line: noinitrd console=ttySAC0,115200 init=/linuxrc mem=64M&nbsp; root<br>=/dev/nfs rw nfsroot=10.1.0.128:/nfsboot&nbsp; ip=10.1.0.129:10.1.128:10.1.0.1:255.25<br>5.255.0::eth0:off</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">... ...</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">【4】内核配置菜单中的mini2440 选项和实际代码是如何关联的</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">在开始移植其他驱动之前，我们再了解一些看起来比较“神秘”的常识，那就是运行make menuconfig 时，内核配置菜单中的mini2440 选项是如何出现的。需要确保前面已经执行了make mini2440_defconfig 加载了缺省配置，因为在x86平台下下执行此操作，系统默认的是x86平台，而且还要在顶层Makefile里作了如下修改：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">export KBUILD_BUILDHOST := $(SUBARCH)<br><strong><font color="#0000ff">ARCH&nbsp;&nbsp;?= arm<br>CROSS_COMPILE&nbsp;?= arm-linux-</font></strong></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">现在在终端中进入到linux-2.6.32.2根目录下执行：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[root@localhost linux-2.6.32.2]#&nbsp;<strong><font color="#0000ff">make menuconfig</font></strong></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">出现下图所示内核配置根菜单</p><p align="center" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><img alt="Linux-2.6.32.2移植---内核移植之构建自定义开发平台 - singleboy - singleboy的博客" src="http://image59.360doc.com/DownloadImg/2013/04/0300/31374908_1.png" style="border: 0px; max-width: 100%; margin: 0px 10px 0px 0px;"></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;按上下箭头键移动到 System Type，按回车进入该子菜单，如图</p><p align="center" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><img alt="Linux-2.6.32.2移植---内核移植之构建自定义开发平台 - singleboy - singleboy的博客" src="http://image59.360doc.com/DownloadImg/2013/04/0300/31374908_2.png" style="border: 0px; max-width: 100%; margin: 0px 10px 0px 0px;"></p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;&nbsp;再找到S3C2440 Machines，按回车进入该子菜单，如图</p><p align="center" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><img alt="Linux-2.6.32.2移植---内核移植之构建自定义开发平台 - singleboy - singleboy的博客" src="http://image59.360doc.com/DownloadImg/2013/04/0300/31374908_3.png" style="border: 0px; max-width: 100%; margin: 0px 10px 0px 0px;"></p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">在此就可以看到 Linux 天生内核对mini2440 开发板的支持选项了，那么它们是从哪里来的呢？<br>打开 Linux-2.6.32.2/arch/arm/mach-s3c2440/Kconfig 文件定位到99行附近，可以找到如下信息(黑体部分)：</p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">config MACH_AT2440EVB<br>&nbsp;bool "Avantech AT2440EVB development board"<br>&nbsp;select CPU_S3C2440<br>&nbsp;select S3C_DEV_USB_HOST<br>&nbsp;select S3C_DEV_NAND<br>&nbsp;help<br>&nbsp;&nbsp; Say Y here if you are using the AT2440EVB development board</p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><strong><font color="#0000ff">config MACH_MINI2440<br>&nbsp;bool "MINI2440 development board"<br>&nbsp;select CPU_S3C2440<br>&nbsp;select EEPROM_AT24<br>&nbsp;select LEDS_TRIGGER_BACKLIGHT<br>&nbsp;select SND_S3C24XX_SOC_S3C24XX_UDA134X<br>&nbsp;select S3C_DEV_NAND<br>&nbsp;select S3C_DEV_USB_HOST<br>&nbsp;help<br>&nbsp;&nbsp; Say Y here to select support for the MINI2440. Is a 10cm x 10cm board<br>&nbsp;&nbsp; available via various sources. It can come with a 3.5" or 7" touch LCD.</font></strong></p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">endmenu</p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">现在明白了吧，“MINI2440 development board”正是在这个Kconfig 文件中定义说明的，当然你可以根据自己的喜好改为其他显示信息。这里的显示信息只是在内核配置菜单中出现的，要让选择的配置实际起效，还需要根据此配置在Makefile 中添加相应的代码文件，请看该目录下的Makefile，定位到25行，如下所示：</p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;# Machine support</p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">obj-$(CONFIG_MACH_ANUBIS)&nbsp;+= mach-anubis.o<br>obj-$(CONFIG_MACH_OSIRIS)&nbsp;+= mach-osiris.o<br>obj-$(CONFIG_MACH_RX3715)&nbsp;+= mach-rx3715.o<br>obj-$(CONFIG_ARCH_S3C2440)&nbsp;+= mach-smdk2440.o<br>obj-$(CONFIG_MACH_NEXCODER_2440) += mach-nexcoder.o<br>obj-$(CONFIG_MACH_AT2440EVB) += mach-at2440evb.o<br><strong><font color="#0000ff">obj-$(CONFIG_MACH_MINI2440) += mach-mini2440.o</font></strong></p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">这样，配置文件就跟实际的代码文件通过配置定义联系在一起了，这里的配置定义是“CONFIG_MACH_MINI2440”，内核中还有很多类似的配置定义，并且有的配置定义还存在依赖关系，我们在此就不对它们详细说明了，随着对内核代码结构的不断熟悉，你就会逐渐学会分析和查找你所需要的各种配置和定义等。</p><p align="left" style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">【5】移植Nand 驱动并更改分区信息</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">(1)Linux-2.6.32.2 内核所支持的Nand Flash 类型</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">Linux2.6.32.2 已经自带了大部分Nand Flash 驱动，在linux-2.6.32.2/drivers/mtd/nand/nand_ids.c 文件中，定义了所支持的各种Nand Flash 类型，定位到84行附近，如下所示</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">#define LP_OPTIONS (NAND_SAMSUNG_LP_OPTIONS | NAND_NO_READRDY | NAND_NO_AUTOINCR)<br>#define LP_OPTIONS16 (LP_OPTIONS | NAND_BUSWIDTH_16)</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;/*512 Megabit */<br>&nbsp;{"NAND 64MiB 1,8V 8-bit",&nbsp;0xA2, 0,&nbsp; 64, 0, LP_OPTIONS},<br>&nbsp;{"NAND 64MiB 3,3V 8-bit",&nbsp;0xF2, 0,&nbsp; 64, 0, LP_OPTIONS},<br>&nbsp;{"NAND 64MiB 1,8V 16-bit",&nbsp;0xB2, 0,&nbsp; 64, 0, LP_OPTIONS16},<br>&nbsp;{"NAND 64MiB 3,3V 16-bit",&nbsp;0xC2, 0,&nbsp; 64, 0, LP_OPTIONS16},</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;/* 1 Gigabit */<br>&nbsp;{"NAND 128MiB 1,8V 8-bit",&nbsp;0xA1, 0, 128, 0, LP_OPTIONS},<br>&nbsp;{"NAND 128MiB 3,3V 8-bit",&nbsp;0xF1, 0, 128, 0, LP_OPTIONS},<br>&nbsp;{"NAND 128MiB 1,8V 16-bit",&nbsp;0xB1, 0, 128, 0, LP_OPTIONS16},<br>&nbsp;{"NAND 128MiB 3,3V 16-bit",&nbsp;0xC1, 0, 128, 0, LP_OPTIONS16},</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;/* 2 Gigabit */<br>&nbsp;{"NAND 256MiB 1,8V 8-bit",&nbsp;0xAA, 0, 256, 0, LP_OPTIONS},<br>&nbsp;{"NAND 256MiB 3,3V 8-bit",&nbsp;0xDA, 0, 256, 0, LP_OPTIONS},<br>&nbsp;{"NAND 256MiB 1,8V 16-bit",&nbsp;0xBA, 0, 256, 0, LP_OPTIONS16},<br>&nbsp;{"NAND 256MiB 3,3V 16-bit",&nbsp;0xCA, 0, 256, 0, LP_OPTIONS16},</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;/* 4 Gigabit */<br>&nbsp;{"NAND 512MiB 1,8V 8-bit",&nbsp;0xAC, 0, 512, 0, LP_OPTIONS},<br>&nbsp;{"NAND 512MiB 3,3V 8-bit",&nbsp;0xDC, 0, 512, 0, LP_OPTIONS},<br>&nbsp;{"NAND 512MiB 1,8V 16-bit",&nbsp;0xBC, 0, 512, 0, LP_OPTIONS16},<br>&nbsp;{"NAND 512MiB 3,3V 16-bit",&nbsp;0xCC, 0, 512, 0, LP_OPTIONS16},</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;/* 8 Gigabit */<br>&nbsp;{"NAND 1GiB 1,8V 8-bit",&nbsp;0xA3, 0, 1024, 0, LP_OPTIONS},<br>&nbsp;{"NAND 1GiB 3,3V 8-bit",&nbsp;0xD3, 0, 1024, 0, LP_OPTIONS},<br>&nbsp;{"NAND 1GiB 1,8V 16-bit",&nbsp;0xB3, 0, 1024, 0, LP_OPTIONS16},<br>&nbsp;{"NAND 1GiB 3,3V 16-bit",&nbsp;0xC3, 0, 1024, 0, LP_OPTIONS16},</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;/* 16 Gigabit */<br>&nbsp;{"NAND 2GiB 1,8V 8-bit",&nbsp;0xA5, 0, 2048, 0, LP_OPTIONS},<br>&nbsp;{"NAND 2GiB 3,3V 8-bit",&nbsp;0xD5, 0, 2048, 0, LP_OPTIONS},<br>&nbsp;{"NAND 2GiB 1,8V 16-bit",&nbsp;0xB5, 0, 2048, 0, LP_OPTIONS16},<br>&nbsp;{"NAND 2GiB 3,3V 16-bit",&nbsp;0xC5, 0, 2048, 0, LP_OPTIONS16},</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;/*<br>&nbsp; * Renesas AND 1 Gigabit. Those chips do not support extended id and<br>&nbsp; * have a strange page/block layout !&nbsp; The chosen minimum erasesize is<br>&nbsp; * 4 * 2 * 2048 = 16384 Byte, as those chips have an array of 4 page<br>&nbsp; * planes 1 block = 2 pages, but due to plane arrangement the blocks<br>&nbsp; * 0-3 consists of page 0 + 4,1 + 5, 2 + 6, 3 + 7 Anyway JFFS2 would<br>&nbsp; * increase the eraseblock size so we chose a combined one which can be<br>&nbsp; * erased in one go There are more speed improvements for reads and<br>&nbsp; * writes possible, but not implemented now<br>&nbsp; */<br>&nbsp;{"AND 128MiB 3,3V 8-bit",&nbsp;0x01, 2048, 128, 0x4000,<br>&nbsp; NAND_IS_AND | NAND_NO_AUTOINCR |NAND_NO_READRDY | NAND_4PAGE_ARRAY |<br>&nbsp; BBT_AUTO_REFRESH<br>&nbsp;},</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">&nbsp;{NULL,}<br>};</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">/*<br>*&nbsp;Manufacturer ID list<br>*/<br>struct nand_manufacturers nand_manuf_ids[] = {<br>&nbsp;{NAND_MFR_TOSHIBA, "Toshiba"},<br>&nbsp;{NAND_MFR_SAMSUNG, "Samsung"},<br>&nbsp;{NAND_MFR_FUJITSU, "Fujitsu"},<br>&nbsp;{NAND_MFR_NATIONAL, "National"},<br>&nbsp;{NAND_MFR_RENESAS, "Renesas"},<br>&nbsp;{NAND_MFR_STMICRO, "ST Micro"},<br>&nbsp;{NAND_MFR_HYNIX, "Hynix"},<br>&nbsp;{NAND_MFR_MICRON, "Micron"},<br>&nbsp;{NAND_MFR_AMD, "AMD"},<br>&nbsp;{0x0, "Unknown"}<br>};</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">(2)修改Nand Flash 分区表</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">系统默认的分区不一定是我们所需的，所以要自已修改，除此之外，还有 Nand Flash的结构信息需要增加填写，以便能够适合系统自带的Nand Flash 驱动接口，这可以参考SMDK2440 中关于Nand Flash 设备注册的一些信息。<br>打开/arch/arm/plat-s3c24xx/common-smdk.c，定位到110行附近，可以看到这样一个结构体：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">static struct mtd_partition smdk_default_nand_part[] = {<br>&nbsp;[0] = {<br>&nbsp;&nbsp;.name&nbsp;= "Boot Agent",<br>&nbsp;&nbsp;.size&nbsp;= SZ_16K,<br>&nbsp;&nbsp;.offset&nbsp;= 0,<br>&nbsp;},<br>&nbsp;[1] = {<br>&nbsp;&nbsp;.name&nbsp;= "S3C2410 flash partition 1",<br>&nbsp;&nbsp;.offset = 0,<br>&nbsp;&nbsp;.size&nbsp;= SZ_2M,<br>&nbsp;},<br>&nbsp;[2] = {<br>&nbsp;&nbsp;.name&nbsp;= "S3C2410 flash partition 2",<br>&nbsp;&nbsp;.offset = SZ_4M,<br>&nbsp;&nbsp;.size&nbsp;= SZ_4M,<br>&nbsp;},<br>&nbsp;[3] = {<br>&nbsp;&nbsp;.name&nbsp;= "S3C2410 flash partition 3",<br>&nbsp;&nbsp;.offset&nbsp;= SZ_8M,<br>&nbsp;&nbsp;.size&nbsp;= SZ_2M,<br>&nbsp;},<br>&nbsp;[4] = {<br>&nbsp;&nbsp;.name&nbsp;= "S3C2410 flash partition 4",<br>&nbsp;&nbsp;.offset = SZ_1M * 10,<br>&nbsp;&nbsp;.size&nbsp;= SZ_4M,<br>&nbsp;},<br>&nbsp;[5] = {<br>&nbsp;&nbsp;.name&nbsp;= "S3C2410 flash partition 5",<br>&nbsp;&nbsp;.offset&nbsp;= SZ_1M * 14,<br>&nbsp;&nbsp;.size&nbsp;= SZ_1M * 10,<br>&nbsp;},<br>&nbsp;[6] = {<br>&nbsp;&nbsp;.name&nbsp;= "S3C2410 flash partition 6",<br>&nbsp;&nbsp;.offset&nbsp;= SZ_1M * 24,<br>&nbsp;&nbsp;.size&nbsp;= SZ_1M * 24,<br>&nbsp;},<br>&nbsp;[7] = {<br>&nbsp;&nbsp;.name&nbsp;= "S3C2410 flash partition 7",<br>&nbsp;&nbsp;.offset = SZ_1M * 48,<br>&nbsp;&nbsp;.size&nbsp;= SZ_16M,<br>&nbsp;}<br>};</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">这其实就是Nand Flash 的分区表，在Linux-2.6.32.2 中，nand 驱动是被注册为平台设备的，这同样可在这个文件的166行看到如下信息：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">static struct s3c2410_platform_nand smdk_nand_info = {<br>&nbsp;.tacls&nbsp;&nbsp;= 20,<br>&nbsp;.twrph0&nbsp;&nbsp;= 60,<br>&nbsp;.twrph1&nbsp;&nbsp;= 20,<br>&nbsp;.nr_sets&nbsp;= ARRAY_SIZE(smdk_nand_sets),<br>&nbsp;.sets&nbsp;&nbsp;= smdk_nand_sets,<br>};</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">参考以上结构信息，我们也在自己的mach-mini2440.c 中照此添加实现，同时需要参考友善之臂原厂内核中的Nand 分区表，操作如：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">打开/arch/arm/mach-s3c2440/mach-mini2440.c，定位到151行处，将下面更改后的分区表定义结构加入其中：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><br>&nbsp;.lpcsel&nbsp;&nbsp;= ((0xCE6) &amp; ~7) | 1&lt;&lt;4,<br>};</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><font color="#0000ff">/* NAND parititon from 2.4.18-swl5 */</font></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><font color="#ff0000"><strong>static struct mtd_partition mini2440_default_nand_part[] = {<br>&nbsp;[0] = {<br>&nbsp;&nbsp;.name&nbsp;= "boot",&nbsp;</strong><font color="#0000ff">//;</font><font color="#0000ff">这里是bootloader 所在的分区，可以放置u-boot, supervivi 等内容，对应/dev/mtdblock0<br></font><strong>&nbsp;&nbsp;.offset&nbsp;= 0,<br>&nbsp;&nbsp;.size&nbsp;= 0x00040000,&nbsp;//256K<br>&nbsp;},<br>&nbsp;[1] = {<br>&nbsp;&nbsp;.name&nbsp;= "param",&nbsp;</strong><font color="#0000ff">//;这里是supervivi 的参数区，其实也属于bootloader 的一部分，如果u-boot 比较大，可以把此区域覆盖掉，不会影响系统启动，对应/dev/mtdblock1<br></font><strong>&nbsp;&nbsp;.offset = 0x00040000,<br>&nbsp;&nbsp;.size&nbsp;= 0x00020000,<br>&nbsp;},<br>&nbsp;[2] = {<br>&nbsp;&nbsp;.name&nbsp;= "kernel",&nbsp;</strong><font color="#0000ff">//;内核所在的分区，大小为5M，足够放下大部分自己定制的巨型内核了，比如内核使用了更大的Linux Logo 图片等，对应/dev/mtdblock2<br></font><strong>&nbsp;&nbsp;.offset = 0x00060000,<br>&nbsp;&nbsp;.size&nbsp;= 0x00500000,<br>&nbsp;},<br>&nbsp;[3] = {<br>&nbsp;&nbsp;.name&nbsp;= "rootfs",&nbsp;</strong><font color="#0000ff">//;文件系统分区，友善之臂主要用来存放yaffs2 文件系统内容，对应/dev/mtdblock3<br></font><strong>&nbsp;&nbsp;.offset&nbsp;= 0x00560000,<br>&nbsp;&nbsp;.size&nbsp;= 1024 * 1024 * 1024,<br>&nbsp;},<br>&nbsp;[4] = {<br>&nbsp;&nbsp;.name&nbsp;= "nand",&nbsp;</strong><font color="#0000ff">//;此区域代表了整片的nand flash，主要是预留使用，比如以后可以通过应用程序访问读</font><strong>取/dev/mtdblock4 就能实现备份整片nand flash 了。<br>&nbsp;&nbsp;.offset = 0x00000000,<br>&nbsp;&nbsp;.size&nbsp;= 1024 * 1024 * 1024,<br>&nbsp;}&nbsp;<br>};</strong></font></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><font color="#ff0000"><font color="#0000ff">//;这里是开发板的nand flash 设置表，因为板子上只有一片，因此也就只有一个表<br></font><strong>static struct s3c2410_nand_set mini2440_nand_sets[] = {<br>&nbsp;[0] = {<br>&nbsp;&nbsp;.name&nbsp;&nbsp;= "NAND",<br>&nbsp;&nbsp;.nr_chips&nbsp;= 1,<br>&nbsp;&nbsp;.nr_partitions&nbsp;= ARRAY_SIZE(mini2440_default_nand_part),<br>&nbsp;&nbsp;.partitions&nbsp;= mini2440_default_nand_part,<br>&nbsp;},<br>};</strong></font></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><font color="#ff0000"><font color="#0000ff">/* choose a set of timings which should suit most 512Mbit<br>&nbsp;* chips and beyond.<br>*/<br></font><font color="#0000ff">//;这里是nand flash 本身的一些特性，一般需要对照datasheet 填写，大部分情况下按照以下参数填写即可<br></font><strong>static struct s3c2410_platform_nand mini2440_nand_info = {<br>&nbsp;.tacls&nbsp;&nbsp;= 20,<br>&nbsp;.twrph0&nbsp;&nbsp;= 60,<br>&nbsp;.twrph1&nbsp;&nbsp;= 20,<br>&nbsp;.nr_sets&nbsp;= ARRAY_SIZE(mini2440_nand_sets),<br>&nbsp;.sets&nbsp;&nbsp;= mini2440_nand_sets,<br>&nbsp;.ignore_unset_ecc = 1,<br>};<br></strong></font>除此之外，还需要把nand flash 设备注册到系统中</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">static struct platform_device *mini2440_devices[] __initdata = {<br>&nbsp;&amp;s3c_device_usb,<br>&nbsp;&amp;s3c_device_lcd,<br>&nbsp;&amp;s3c_device_wdt,<br>&nbsp;&amp;s3c_device_i2c0,<br>&nbsp;&amp;s3c_device_iis,<br>&nbsp;<strong><font color="#ff0000">&amp;s3c_device_nand,</font></strong>&nbsp;<font color="#0000ff">//;把nand flash 设备添加到开发板的设备列表结构<br></font>};<br>(3)加入编译头文件</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">在上面的文件中定位到50行附近，加入一下头文件：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><strong><font color="#ff0000">#include &lt;linux/mtd/mtd.h&gt;&nbsp;<br>#include &lt;linux/mtd/nand.h&gt;&nbsp;<br>#include &lt;linux/mtd/nand_ecc.h&gt;&nbsp;<br>#include &lt;linux/mtd/partitions.h&gt;&nbsp;<br>#include &lt;plat/nand.h&gt;</font></strong></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">(4)传入<font color="#000000">mini2440_nand_info结构体初始化参数</font></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">定位到223行附近，修改如下：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">static void __init mini2440_machine_init(void)<br>{<br>&nbsp;&nbsp;s3c_i2c0_set_platdata(NULL);<br>&nbsp;<strong><font color="#ff0000">s3c_device_nand.dev.platform_data = &amp;mini2440_nand_info;&nbsp;<br></font></strong>&nbsp;platform_add_devices(mini2440_devices, ARRAY_SIZE(mini2440_devices));<br>&nbsp;//smdk_machine_init();<br>}</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">然后保存。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);"><strong>1.2，</strong>编译测试</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">至此，就完成了nand flash 驱动的移植，修改完成之后，最好在每次进行make menuconfig后都有执行</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[root@localhost linux-2.6.32.2]# make clean</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">因为内核中已经可能已经增减了要编译的模块，所以要在编译之前清除下已编译的目标模块，不然可能编译出错，然后进行编译：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[root@localhost linux-2.6.32.2]# make uImage</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">编译完成后，生成zImage文件，然后给开发板上电，启动u-boot，操作如下：</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[u-boot@MINI2440]#&nbsp;<strong><font color="#0000ff">tftp 31000000 uImage<br></font></strong></p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">... ...</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">S3C24XX NAND Driver, (c) 2004 Simtec Electronics<br>s3c24xx-nand s3c2440-nand: Tacls=3, 29ns Twrph0=7 69ns, Twrph1=3 29ns<br>s3c24xx-nand s3c2440-nand: NAND soft ECC<br><strong><font color="#0000ff">NAND device: Manufacturer ID: 0xec, Chip ID: 0xf1 (Samsung NAND 128MiB 3,3V 8-bit)<br>Scanning device for bad blocks<br>Creating 5 MTD partitions on "NAND 128MiB 3,3V 8-bit":<br>0x000000000000-0x000000040000 : "boot"<br>uncorrectable error :<br>0x000000040000-0x000000060000 : "param"<br>ftl_cs: FTL header not found.<br>0x000000060000-0x000000560000 : "kernel"<br>ftl_cs: FTL header not found.<br>0x000000560000-0x000040560000 : "root"<br>mtd: partition "root" extends beyond the end of device "NAND 128MiB 3,3V 8-bit"<br>-- size truncated to 0x7aa0000<br>ftl_cs: FTL header not found.<br>0x000000000000-0x000040000000 : "nand"<br>mtd: partition "nand" extends beyond the end of device "NAND 128MiB 3,3V 8-bit"<br>-- size truncated to 0x8000000<br></font></strong>uncorrectable error :<br>dm9000 Ethernet Driver, V1.31<br>ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver<br>s3c2410-ohci s3c2410-ohci: S3C24XX OHCI<br>s3c2410-ohci s3c2410-ohci: new USB bus registered, assigned bus number 1<br>s3c2410-ohci s3c2410-ohci: irq 42, io mem 0x49000000<br>usb usb1: configuration #1 chosen from 1 choice<br>hub 1-0:1.0: USB hub found<br>hub 1-0:1.0: 2 ports detected</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">可以在启动时看到如图蓝色信息，它们正是我们刚刚添加的nand flash 分区信息，以及开发板本身nand flash 的一些信息，这里可以看到是128M 的nand flash。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">.. ....</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">rpcbind: server 10.1.0.128 not responding, timed out<br>Root-NFS: Unable to get nfsd port number from server, using default<br>Looking up port of RPC 100005/1 on 10.1.0.128<br>rpcbind: server 10.1.0.128 not responding, timed out<br>Root-NFS: Unable to get mountd port number from server, using default<br>Root-NFS: Server returned error -5 while mounting /nfsboot<br>VFS: Unable to mount root fs via NFS, trying floppy.<br>VFS: Cannot open root device "nfs" or unknown-block(2,0)<br>Please append a correct "root=" boot option; here are the available partitions:<br><strong><font color="#0000ff">1f00&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 256 mtdblock0 (driver?)<br>1f01&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 128 mtdblock1 (driver?)<br>1f02&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 5120 mtdblock2 (driver?)<br>1f03&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 125568 mtdblock3 (driver?)<br>1f04&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 131072 mtdblock4 (driver?)<br>Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)<br></font></strong>[&lt;c002e9c0&gt;] (unwind_backtrace+0x0/0xd8) from [&lt;c02d4798&gt;] (panic+0x40/0x118)<br>[&lt;c02d4798&gt;] (panic+0x40/0x118) from [&lt;c0008e68&gt;] (mount_block_root+0x1c8/0x208)</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">[&lt;c0008e68&gt;] (mount_block_root+0x1c8/0x208) from [&lt;c00090fc&gt;] (prepare_namespace<br>+0x160/0x1b8)<br>[&lt;c00090fc&gt;] (prepare_namespace+0x160/0x1b8) from [&lt;c0008434&gt;] (kernel_init+0xd8<br>/0x10c)<br>[&lt;c0008434&gt;] (kernel_init+0xd8/0x10c) from [&lt;c002a868&gt;] (kernel_thread_exit+0x0/<br>0x8)</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">这里提示的挂在分区时出现了问题。</p><p style="line-height: 25px; margin: 0px 0px 10px; padding: 0px; font-family: Arial, Helvetica, simsun, u5b8bu4f53; font-size: 14px; background-color: rgb(204, 206, 208);">接下来，将为linux-2.6.32.2添加yaffs文件系统。</p></div>
                                                                                        </td>
                                                                                    </tr>
                                                                                </tbody>
                                                                            </table>
                                                                            <div id="viewerPlaceHolder" style="width: 717px; height: 700px; display: none;">
                                                                            </div>
                                                                        </span>
                                                                        <table>
                                                                            <tbody>
                                                                                <tr>
                                                                                    <td></td>
                                                                                </tr>
                                                                            </tbody>
                                                                        </table>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td align="left">
                                                                        <a name="anchordoc1" id="anchordoc1"></a>
                                                                        <div style="height: 28px">
                                                                            <div style="font-size: 14px; color: #797b7a; float: left;">
                                                                                来自：<span class="name" onclick="wzhitnew(59)"><A href="http://www.360doc.com/userhome/7044580" target="_blank">joy_chen</A></span>&nbsp;>&nbsp;<span
                                                                                    id="cname" onclick="wzhitnew(60)"></span>
                                                                            </div>
                                                                            <div style="float: left;">
                                                                                <div class="btzctsg" id="spanfollowstatus1">
                                                                                </div>
                                                                                <script>isfollow(7044580);</script>
                                                                            </div>
                                                                        </div>
                                                                        <div>
                                                                            <div class="modlist lf360 list" style="padding-top: 0px;">
                                                                                <ul>
                                                                                    <div id='lastart'>
                                                                                    </div>
                                                                                    <div id='nextart'>
                                                                                    </div>
                                                                                </ul>
                                                                            </div>
                                                                        </div>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td align="left">
                                                                        <div style="padding-top: 12px;">
                                                                            <script type="text/javascript">
                                                                                /*文章页正文下方标签云，2013-8-21*/
                                                                                var cpro_id = "u1350774";
                                                                            </script>
                                                                            <script src="http://cpro.baidustatic.com/cpro/ui/c.js" type="text/javascript"></script>
                                                                        </div>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td style="text-align: left;">
                                                                        <div style="padding-top: 15px; width: 670px;">
                                                                            <table style="width: 670px;" cellpadding="0" cellspacing="0">
                                                                                <tbody>
                                                                                    <tr>

                                                                                        <td style="width: 530px;">
                                                                                            <div class=" lf360" style="cursor: pointer" onmouseover="ChangeBtnStyle(1);" onmouseout="ChangeBtnStyle(2);">
                                                                                                <div class="zscbt">
                                                                                                    <a href="javascript:void(0);" onclick="SaveArt();wzhitnew(26);">
                                                                                                        <div id="zscbtword" class="lf360 xianhua" style="padding-left: 38px;">
                                                                                                            转藏到我的图书馆
                                                                                                        </div>
                                                                                                    </a>
                                                                                                </div>
                                                                                            </div>

                                                                                            <div style="margin-left: 10px; cursor: pointer;" class="lf360 xhmainbox" id="sendflowerdiv"
                                                                                                onclick='Showflowerlayer("sendedLayer1");wzhitnew(27)' onmouseover="ChangeFlowerBtnStyle(1);"
                                                                                                onmouseout="ChangeFlowerBtnStyle(2);">

                                                                                                <div id="flowimg2" class="lf360">
                                                                                                    <div style="padding-left: 10px; padding-top: 10px;">
                                                                                                        <img id="flowimg3" src="http://pubimage.360doc.com/wz/huahuanew.gif">
                                                                                                    </div>
                                                                                                </div>
                                                                                                <div id="flowimg5" class=" lf360 xianhua">
                                                                                                    献花(<span id="articleflowernum">0</span>)<div id='flowernumadd' class="addtionone">
                                                                                                        +1
                                                                                                    </div>
                                                                                                </div>

                                                                                            </div>




                                                                                            <div class="lf360" style="cursor: pointer; padding-left: 10px;" onmouseover="ChangeBtnStyle(3);" onmouseout="ChangeBtnStyle(4);">
                                                                                                <div class="fxwxbt">

                                                                                                    <a href="javascript:void(0);" onclick="shareWeixin();wzhitnew(64);">
                                                                                                        <div id="fxwxword" class="lf360 xianhua" style="padding-left: 38px;">
                                                                                                            分享到微信
                                                                                                        </div>
                                                                                                    </a>
                                                                                                </div>
                                                                                            </div>





                                                                                            <div class="lf360" style="cursor: pointer; padding-left: 10px;" onmouseover="ChangeBtnStyle(5);" onmouseout="ChangeBtnStyle(6);">
                                                                                                <div class="ywzwbt">

                                                                                                    <a href=" http://www.baidu.com/s?wd=nand+mini+mach&tn=SE_hldp01010_6r0gix1f" onclick="wzhitnew(100);" target="_blank">
                                                                                                        <div id="ywzwword" class="lf360 xianhua" style="padding-left: 44px;">
                                                                                                            以文找文
                                                                                                        </div>
                                                                                                    </a>

                                                                                                </div>
                                                                                            </div>
                                                                                        </td>
                                                                                        <td style="vertical-align: bottom; font-size: 12px;" width="140">
                                                                                            <div class="rt360" id="sharediv2">
                                                                                            </div>
                                                                                        </td>
                                                                                    </tr>
                                                                                </tbody>
                                                                            </table>
                                                                        </div>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td height="10"></td>
                                                                </tr>
                                                            </tbody>
                                                        </table>
                                                    </td>
                                                </tr>
                                            </tbody>
                                        </table>
                                    </td>
                                </tr>
                            </tbody>
                        </table>
                        <div class="lswzbox" style="padding-top: 10px;">
                            <div>
                                <table cellpadding="0" cellspacing="0">
                                    <tbody>
                                        <tr>
                                            <td width="330" valign="top">
                                                <div class="lswz" style="height: 300px;">
                                                    <div class="lstwtop">
                                                        <div class="lswztit">
                                                            <div class=" lf360">
                                                                <div class="titwx1">
                                                                    类似文章
                                                                </div>
                                                            </div>
                                                            <div class="rt360" style="padding-top: 5px; padding-right: 9px;">
                                                                <a href=http://www.360doc.com/relevant/275633208_more.shtml  target='_blank'  onclick='wzhitnew(38)'>更多</a>
                                                            </div>
                                                        </div>
                                                        <div class="modlist2 list">
                                                            <ul>
                                                                
                                                                        <li style="height: 30px; line-height: 30px;"><span>
                                                                            <a href=http://www.360doc.com/content/13/0916/02/11400509_314729072.shtml target=_blank onclick='wzhitnew(37)'>移植3.4.2内核 到tiny6410</a></span></li>
                                                                    
                                                                        <li style="height: 30px; line-height: 30px;"><span>
                                                                            <a href=http://www.360doc.com/content/12/0705/15/9072830_222419994.shtml target=_blank onclick='wzhitnew(37)'>Linux 2.6.37内核移植到Mini2440（二）</a></span></li>
                                                                    
                                                                        <li style="height: 30px; line-height: 30px;"><span>
                                                                            <a href=http://www.360doc.com/content/11/0426/13/6828497_112434964.shtml target=_blank onclick='wzhitnew(37)'>Linux 2.6.36内核移植飞凌OK6410开发板步....</a></span></li>
                                                                    
                                                                        <li style="height: 30px; line-height: 30px;"><span>
                                                                            <a href=http://www.360doc.com/content/12/0125/17/8388102_181815497.shtml target=_blank onclick='wzhitnew(37)'>4. Linux2.6.14内核编译、移植 (含LCD移...</a></span></li>
                                                                    
                                                                        <li style="height: 30px; line-height: 30px;"><span>
                                                                            <a href=http://www.360doc.com/content/11/1029/23/1317564_160201730.shtml target=_blank onclick='wzhitnew(37)'>linux 2.6.32 在arm9（s3c2440）平台的移....</a></span></li>
                                                                    
                                                                        <li style="height: 30px; line-height: 30px;"><span>
                                                                            <a href=http://www.360doc.com/content/12/0705/11/9072830_222378829.shtml target=_blank onclick='wzhitnew(37)'>(精)移植linux2.6.29内核到mini2440</a></span></li>
                                                                    
                                                                        <li style="height: 30px; line-height: 30px;"><span>
                                                                            <a href=http://www.360doc.com/content/11/0126/08/2646522_89065567.shtml target=_blank onclick='wzhitnew(37)'>mini2440 linux移植 nandflash驱动的移植....</a></span></li>
                                                                    
                                                                        <li style="height: 30px; line-height: 30px;"><span>
                                                                            <a href=http://www.360doc.com/content/10/1203/21/1378815_74783642.shtml target=_blank onclick='wzhitnew(37)'>linux2.6移植+根文件系统实验手册</a></span></li>
                                                                    
                                                            </ul>
                                                        </div>

                                                    </div>
                                                </div>
                                            </td>

                                            <td width="330" valign="top">
                                                <div class="lswz" style="margin-left: 9px; height: 300px;">
                                                    <div class="lstwtop">
                                                        <div class="lswztit">
                                                            <div class=" lf360">
                                                                <div class="titwx1">
                                                                    热门推广
                                                                </div>
                                                            </div>
                                                            <div class="rt360" style="padding-top: 5px; padding-right: 9px;">
                                                            </div>
                                                        </div>
                                                        <div class="modlist2 list" style="width: 300px; overflow: hidden; margin-top: 5px;">
                                                            <script type="text/javascript">
                                                                var sogou_ad_id = 268217;
                                                                var sogou_ad_height = 242;
                                                                var sogou_ad_width = 298;
                                                            </script>
                                                            <script type='text/javascript' src='http://images.sohu.com/cs/jsfile/js/c.js'></script>

                                                        </div>
                                                    </div>
                                                </div>
                                            </td>

                                        </tr>
                                    </tbody>
                                </table>
                                <div style="background-color: #fafafa; width: 670px; height: 317px; margin-top: 10px;">
                                    <div style=' padding-top:7px; padding-left:12px; height:182px;'> <div style=' height:30px;'><div class='titwx3 lf360'>猜你喜欢</div><div class=' rt360' style=' padding-right:18px;'><img onclick='changefiveart("19999","19999");wzhitnew(62);' src='http://pubimage.360doc.com/wz/hyz.gif' onmouseover='this.src="http://pubimage.360doc.com/wz/hyza.gif"' onmouseout='this.src="http://pubimage.360doc.com/wz/hyz.gif"' width='76' height='24' style='cursor:pointer;' /></div></div><table cellpadding='0' cellspacing='0'><tr id='fivearttdid'><td valign='top' width='131'><div><a onclick='wzhitnew(39);' href='http://www.360doc.com/content/14/0408/18/4503649_367308769.shtml' target='_blank'><img src='http://artpic.360doc.com/14/0512/05/367308769_201405120524370384.jpg' width='114' height='86'/></a></div><div class='lan twentit'><a  onclick='wzhitnew(40);' href='http://www.360doc.com/content/14/0408/18/4503649_367308769.shtml' target='_blank'>70条提升个人礼仪素质的小贴士</a></div></td><td valign='top' width='131'><div><a onclick='wzhitnew(39);' href='http://www.360doc.com/content/14/0205/10/3256622_349912608.shtml' target='_blank'><img src='http://artpic.360doc.com/14/0219/09/349912608_201402190918100694.jpg' width='114' height='86'/></a></div><div class='lan twentit'><a  onclick='wzhitnew(40);' href='http://www.360doc.com/content/14/0205/10/3256622_349912608.shtml' target='_blank'>身体好不好看脸就知道</a></div></td><td valign='top' width='131'><div><a onclick='wzhitnew(39);' href='http://www.360doc.com/content/13/1205/22/7625451_334824217.shtml' target='_blank'><img src='http://artpic.360doc.com/13/1213/00/7625451_201312130010060736.jpg' width='114' height='86'/></a></div><div class='lan twentit'><a  onclick='wzhitnew(40);' href='http://www.360doc.com/content/13/1205/22/7625451_334824217.shtml' target='_blank'>奇幻宇宙</a></div></td><td valign='top' width='131'><div><a onclick='wzhitnew(39);' href='http://www.360doc.com/content/13/0101/18/5260666_257517312.shtml' target='_blank'><img src='http://artpic.360doc.com/13/0830/12/5260666_201308301211130593_a257517312.jpg' width='114' height='86'/></a></div><div class='lan twentit'><a  onclick='wzhitnew(40);' href='http://www.360doc.com/content/13/0101/18/5260666_257517312.shtml' target='_blank'>抛开恐惧，挑战死亡——与死神共进晚餐</a></div></td><td valign='top' width='131'><div><a onclick='wzhitnew(39);' href='http://www.360doc.com/content/14/0107/21/14102547_343435456.shtml' target='_blank'><img src='http://artpic.360doc.com/14/0114/00/14102547_201401140010050906.jpg' width='114' height='86'/></a></div><div class='lan twentit'><a  onclick='wzhitnew(40);' href='http://www.360doc.com/content/14/0107/21/14102547_343435456.shtml' target='_blank'>珍贵的甲骨文对照表</a></div></td></tr></table></div>
                                    <div style="padding-left: 12px;">
                                        <iframe marginwidth="0" marginheight="0" frameborder="0" scrolling="no" width="650" height="100" src="http://www.360doc.com/ad/artadali4.html?t=2014012301"></iframe>
                                    </div>
                                    <div id="adabtest">
                                    </div>

                                </div>





                                <div id="Reflction" style="padding-top: 15px; padding-left: 15px;">
                                    <div id="360docRefTN">
                                    </div>
                                    <div id="360docRefCT">
                                    </div>
                                    <div id="360docRefPB" align="center">
                                    </div>
                                </div>
                                <a name="sf"></a>
                                
                                <div id="ReflectionPart">
                                    <div style="height: 206px; margin: 0px 0px;">
                                        <div class="plbox">
                                            <div class="plmain">
                                                <div class="titwx" style="height: 23px;">
                                                    发表评论：
                                                </div>
                                                <textarea name="SendRefTB" id="SendRefTB" style="width: 100%; height: 75px; border: 1px solid #e7e7e7; background-color: #fff; overflow: auto; font-size: 12px;"
                                                    onfocus="testContent(1);" onblur="testContent(2)"></textarea>
                                                <div style="text-align: right; padding-right: 3px; padding-top: 6px;">
                                                    <div class="huifubt">
                                                        <a id="ImgSendPL" href="javascript:void(0);"></a>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </td>
                    <td align="center" valign="top" width="18px"></td>
                    <td align="left" valign="top" width="252px">
                        


<div style='height: 98px' id="artrightad1">
 
</div>


    <div class="remenwz" style="height:219px;"><div class="rementop"><div class="titwx" style=" padding-top:10px; padding-left:24px;">最新文章</div></div><div class="modlist3 list" style=" padding-left:15px;"><ul><li><span><a href=http://www.360doc.com/content/14/0801/11/7044580_398559908.shtml target=_blank onclick='wzhitnew(51)'>护照 港澳通行证</a></span></li><li><span><a href=http://www.360doc.com/content/14/0719/17/7044580_395524736.shtml target=_blank onclick='wzhitnew(51)'>LCD常见问题</a></span></li><li><span><a href=http://www.360doc.com/content/14/0714/11/7044580_394285078.shtml target=_blank onclick='wzhitnew(51)'>线程的同步与锁</a></span></li><li><span><a href=http://www.360doc.com/content/14/0713/21/7044580_394183382.shtml target=_blank onclick='wzhitnew(51)'>JAVA通过JNI调用本地C语言方法</a></span></li><li><span><a href=http://www.360doc.com/content/14/0713/20/7044580_394175726.shtml target=_blank onclick='wzhitnew(51)'>Android官方提供的支持不同屏幕...</a></span></li><li><span><a href=http://www.360doc.com/content/14/0712/16/7044580_393910873.shtml target=_blank onclick='wzhitnew(51)'>Android睡眠唤醒机制</a></span></li></ul> <div class=" rt360" style=" padding-right:23px;"><a href="http://www.360doc.com/userhome/7044580" target="_blank" onclick="wzhitnew(52);">更多</a></div></div></div>


<div class="both" style="padding-top: 10px; height: 260px;">
   <iframe id="ifartad1" height="250px" width="250px" frameborder="0" scrolling="no"></iframe>
    <div style="height: 10px;">
    </div>
</div>

<div class="remenwz">
    <div class="rementop">
        <div class="titwx" style="padding-top: 10px; padding-left: 24px;">
            热门文章</div>
    </div>
    <div class="modlist3 list" style="padding-left: 15px;">
        <ul>
            
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0126/13/0_348086240.shtml target=_blank onclick='wzhitnew(55)'>中国现今90%以上官员都应该被辞...</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0206/04/0_350103010.shtml target=_blank onclick='wzhitnew(55)'>100幅风光大片，让你饱览世界无...</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0725/03/0_396864541.shtml target=_blank onclick='wzhitnew(55)'>用触目惊心的数据和实拍图片说...</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0425/20/0_372200041.shtml target=_blank onclick='wzhitnew(55)'>刘氏美女</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0205/15/0_349972067.shtml target=_blank onclick='wzhitnew(55)'>76张彩图详解男女人体器官及病...</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0220/14/0_354196871.shtml target=_blank onclick='wzhitnew(55)'>一图看懂]7个步骤，带好你的团...</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/13/1129/19/0_333257055.shtml target=_blank onclick='wzhitnew(55)'>有一种爱，需要你去感觉</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/13/1024/05/0_323665450.shtml target=_blank onclick='wzhitnew(55)'>中国最美的婉约词欣赏</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0223/14/0_355005240.shtml target=_blank onclick='wzhitnew(55)'>中国人应该知道的15个典故 ----...</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0507/09/0_375402547.shtml target=_blank onclick='wzhitnew(55)'>【书法极品】漂亮难得的好字《...</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/13/1024/09/0_323684304.shtml target=_blank onclick='wzhitnew(55)'>家烧豆腐</a></span></li>
                
                    <li><span>
                        <a href=http://www.360doc.com/content/14/0304/08/0_357544456.shtml target=_blank onclick='wzhitnew(55)'>【清纯美女】邻家女孩—谢翔雅</a></span></li>
                
        </ul>
        <div class=" rt360" style="padding-right: 23px;">
            <a href="http://www.360doc.com/readroom.html" target="_blank" onclick='wzhitnew(56)'>更多>></a></div>
    </div>
</div>

<div class="both" style="padding-top: 10px;">
    <iframe id="ifartad2" height="250px" width="250px" frameborder="0" scrolling="no"></iframe>
</div>
<br />

<script type="text/javascript">
    var sogou_ad_id = 261623;
    var sogou_ad_height = 328;
    var sogou_ad_width = 250;
</script>
<script language='JavaScript' type='text/javascript' src='http://images.sohu.com/cs/jsfile/js/c.js'></script>
<script>
    function change(pro_name, i) {
        var pro = document.getElementById(pro_name); 
        var pro_arr = pro.getElementsByTagName("span");

        for (var m = 0; m < pro_arr.length; m++) {
            pro_arr[m].className = "unclecked link_black";
        }
        pro_arr[i].className = "checked link_bai";

        if (i == 1) {
            document.getElementById("qh_ul_1").style.display = "";
            document.getElementById("qh_ul_0").style.display = "none";
        }
        else if (i == 0) {
            document.getElementById("qh_ul_1").style.display = "none";
            document.getElementById("qh_ul_0").style.display = "";
        }
    }
</script>

                        <div class="both" id="divad5" style="padding-top: 11px; zoom: 1;">
                            <div id="divad4" style="display: none;">
                                <div>
                                    <iframe id="ifartad" height="250px" width="250px" frameborder="0" scrolling="no"></iframe>
                                </div>
                                <div class="ggwz">
                                    <a href="javascript:void(0);" onclick="closead(2);">关闭</a>
                                </div>
                                <div style="height: 13px;">
                                </div>
                            </div>
                            <div style="clear: both; display: none;" id="divad6">
                                <div>
                                    <script type="text/javascript">
                                        /*文章页右下滚屏200*200，创建于2013-7-22*/
                                        var cpro_id = "u1324965";
                                    </script>
                                    <script src="http://cpro.baidustatic.com/cpro/ui/c.js" type="text/javascript"></script>
                                </div>
                                <div class="ggwz">
                                    <a href="javascript:void(0);" onclick="closead(3);">关闭</a>
                                </div>
                                <div style="height: 13px;">
                                </div>
                            </div>

                        </div>
                    </td>
                </tr>
            </tbody>
        </table>
    </div>
    <input type="hidden" id="docarttitle" value="Linux-2.6.32.2%e5%86%85%e6%a0%b8%e5%9c%a8mini2440%e4%b8%8a%e7%9a%84%e7%a7%bb%e6%a4%8d" />
    <input type="hidden" id="artreadroomid" value="0" />
    <script>var asw='nand+mini+mach'</script>
    <div id="docdiviframe"></div>


    <script language="javascript" type="text/javascript">
        var appName = navigator.appName.toLowerCase();
        if (appName.indexOf("microsoft internet explorer") > -1) {
            document.write("<scr" + "ipt type='text/javascript' src='http://www.360doc.com/js/StickySystemIE20130911.js?t=2014072501'></sc" + "ript>");
        }
        else {

            document.write("<scr" + "ipt type='text/javascript' src='http://www.360doc.com/js/StickySystemOther20130911.js?t=2014072501'></sc" + "ript>");
        }
    </script>

    <script>GerLookingUserInfo(1,7044580,1,1,'-1',-1,10,0);OutputSource('http%3a%2f%2fsingleboy.blog.163.com%2fblog%2fstatic%2f5490019420114251536390%2f');OutputCategory(7044580,37,'%e3%80%8aporting%e3%80%8b');OutputLastNextArt('%e5%9c%a8Devkit8000%e5%bc%80%e5%8f%91%e6%9d%bf%e4%b8%8a%e5%ae%9e%e7%8e%b0android%e7%8e%af%e5%a2%83%e8%bf%90%e8%a1%8c','http://www.360doc.com/content/13/0402/17/7044580_275556767.shtml',0);OutputLastNextArt('OK6410%e4%b9%8blinux-2.6.39.2%e5%86%85%e6%a0%b8%e7%9a%84%e7%a7%bb%e6%a4%8d%e6%84%9a%e8%a7%81','http://www.360doc.com/content/13/0504/20/7044580_282977116.shtml',1);</script>

    <script type="text/javascript">
        var _bdhmProtocol = (("https:" == document.location.protocol) ? " https://" : " http://");
        document.write(unescape("%3Cscript src='" + _bdhmProtocol + "hm.baidu.com/h.js%3Fd86954201130d615136257dde062a503' type='text/javascript'%3E%3C/script%3E"));
    </script>

    <script type="text/javascript" id="bdshare_js" data="type=tools&amp;uid=6857724" src="http://bdimg.share.baidu.com/static/js/bds_s_v2.js?cdnversion=384393"></script>

    <script type="text/javascript">
        document.getElementById("bdshell_js").src = "http://bdimg.share.baidu.com/static/js/shell_v2.js?cdnversion=" + Math.ceil(new Date() / 3600000);
    </script>
    <!-- Baidu Button END -->
    <script src="http://bdimg.share.baidu.com/static/js/logger.js?cdnversion=384393"></script>
</body>
</html>
